/*INCLUDES-------------------------------------------------------------------*/

#include <string.h>

#include "ses_display_print.h"
#include "ses_display.h"
#include "font6x8.h"

/*MACROS---------------------------------------------------------------------*/


/*VARIABLES------------------------------------------------------------------*/

static FILE file;




/*FUNCTION DEFINITION--------------------------------------------------------*/

/**
 * Wrapper for writing characters to the LCD. Function signature allows
 * usage in a file descriptor.
 *
 * @param chr		character to write
 * @param stream	passed stream instance
 */
static int put(char chr, FILE *stream) {
	displayPrint_put(chr);
	return 0;
}



void displayPrint_init() {
	display_init();
	display_clear();




	// TODO




	// DO NOT DELETE THESE LINES
	// initialize file descriptor in order to allow access display via fprintf
	memset(&file, 0, sizeof(FILE));
	file.put = put;
	file.get = NULL;
	file.flags = _FDEV_SETUP_WRITE;
	file.udata = 0;
	stdout=&file;
}

void displayPrint_setCursor(uint8_t p, uint8_t r) {
	// TODO
}

void displayPrint_put(char chr) {

	// TODO

}

